package com.zhuoyue.biz.core.api.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.zhuoyue.biz.core.api.domain.TblPasswordShare;
import com.zhuoyue.biz.core.api.dto.rep.LockPasswordShareDTO;
import org.apache.ibatis.annotations.Param;

/**
 * @author wjming
 * @ClassName: TblPasswordShareMapper
 * @Description: 指纹锁临时密码分享数据层
 * @Date 2021-07-07 16:20
 */
public interface TblPasswordShareMapper extends BaseMapper<TblPasswordShare> {

    /**
     * 通过Id获取到分享的密码
     *
     * @param id
     * @return LockPasswordShareDTO
     */
    LockPasswordShareDTO getPasswordShareById(String id);


    /**
     * 根据网关mac和设备mac查询密码详情
     *
     * @param deviceMac
     * @param type
     * @return LockPasswordShareDTO
     */
    LockPasswordShareDTO getPasswordShareByDeviceMac(@Param("deviceMac") String deviceMac, @Param("type") String type);
}
